package rx.report;

import javax.swing.table.AbstractTableModel;



public class TableModel extends AbstractTableModel {

	private String[] columnNames;
	
	private Object[][] data;
	
	public Object[][] getData() {
		return data;
	}

	public void setData(Object[][] data) {
		this.data = data;
	}

	/**
	 *
	 */
	public int getColumnCount()
	{
		return this.columnNames.length;
	}


	/**
	 *
	 */
	public String getColumnName(int columnIndex)
	{
		return this.columnNames[columnIndex];
	}


	/**
	 *
	 */
	public int getRowCount()
	{
		return this.data.length;
	}

	/**
	 *
	 */
	public Object getValueAt(int rowIndex, int columnIndex)
	{
		return this.data[rowIndex][columnIndex];
	}

	public String[] getColumnNames() {
		return columnNames;
	}

	public void setColumnNames(String[] columnNames) {
		this.columnNames = columnNames;
	}

}
